
import java.util.Random;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author pson
 */
public class Die {
    
    private Random random;
    private int sided;

    public Die(int sided) {
        this.sided = sided;
        this.random = new Random();
    }
    
    public int roll() {
        return random.nextInt(sided) + 1;
    }
    
}
